import request from '@/utils/request'
// ----------------红包 start--------------------
// 箱子列表页加载数据
export function ListBoxData(data) {
  return request({
    url: '/battle/ListBoxData',
    method: 'post',
    data
  })
}
// 添加箱子加载普通开箱的箱子
export function getGeneralList() {
  return request({
    url: '/battle/getGeneralList',
    method: 'post'
  })
}
// 添加普通箱子进入对战
// [1,2,3]
export function addBoxToBattle(data) {
  return request({
    url: '/battle/addBoxToBattle',
    method: 'post',
    data
  })
}
// 删除箱子
// [1,2,3]
export function deleteBoxFromBattle(data) {
  return request({
    url: '/battle/deleteBoxFromBattle',
    method: 'post',
    data
  })
}
// 添加自定义箱子
export function saveBoxData(data) {
  return request({
    url: '/battle/saveBoxData',
    method: 'post',
    data
  })
}
// 修改自定义箱子
export function updateBoxData(data) {
  return request({
    url: '/battle/updateBoxData',
    method: 'post',
    data
  })
}
// 获取赠送饰品配置
export function getOtherGoodsList() {
  return request({
    url: '/battle/getOtherGoodsList',
    method: 'post'
  })
}
// 保存赠送饰品配置
export function setOtherGoodsList(data) {
  return request({
    url: '/battle/setOtherGoodsList',
    method: 'post',
    data
  })
}
// 保存对战玩法介绍
// { "data":"1231313" }
export function setBattleDescribe(data) {
  return request({
    url: '/battle/setBattleDescribe',
    method: 'post',
    data
  })
}
// 获取对战玩法介绍
export function getBattleDescribe() {
  return request({
    url: '/battle/getBattleDescribe',
    method: 'post'
  })
}
// 获取相关限制
export function getBattleSetting() {
  return request({
    url: '/battle/getBattleSetting',
    method: 'post'
  })
}
// 保存相关限制
export function setBattleSetting(data) {
  return request({
    url: '/battle/setBattleSetting',
    method: 'post',
    data
  })
}
// 获取AI配置
// 常规箱子id传-1
export function getBattleRobot() {
  return request({
    url: '/battle/getBattleRobot',
    method: 'post'
  })
}
// 保存AI配置
export function setBattleRobot(data) {
  return request({
    url: '/battle/setBattleRobot',
    method: 'post',
    data
  })
}
// AI配置获取对战箱子list
export function getBattleBoxList() {
  return request({
    url: '/battle/getBattleBoxList',
    method: 'post'
  })
}
// AI配置获取AIList
export function getBattleRobotList() {
  return request({
    url: '/battle/getBattleRobotList',
    method: 'post'
  })
}
// 对战房间记录加载数据
export function LisRoomData(data) {
  return request({
    url: '/battle/LisRoomData',
    method: 'post',
    data
  })
}
// 对战玩家记录加载数据
export function LisUserData(data) {
  return request({
    url: '/battle/LisUserData',
    method: 'post',
    data
  })
}
// 对战玩家记录加载数据
export function LisUserRecordByUserId(data) {
  return request({
    url: '/battle/LisUserRecordByUserId',
    method: 'post',
    data
  })
}
// 对战玩家记录加载数据
export function LisUserRecordDetail(data) {
  return request({
    url: '/battle/LisUserRecordDetail',
    method: 'post',
    data
  })
}
// 加载市场饰品下拉菜单(带参)
// {"key":"l","alreadyIds"[1,2,3]}
export function getGoodsPlatformList(data) {
  return request({
    url: '/box/getGoodsPlatformList',
    method: 'post',
    data
  })
}

// 上架状态修改
export function updateBoxUpStatus(data) {
  return request({
    url: '/box/updateBoxUpStatus',
    method: 'post',
    data
  })
}

// 拖动排序
export function updateBoxSort(data) {
  return request({
    url: '/battle/updateGradeSort',
    method: 'post',
    data
  })
}

// 雷场拖动排序
export function updateSlBoxSort(data) {
  return request({
    url: '/minefield/updateSort',
    method: 'post',
    data
  })
}

// 手机号处理
export function dealUserData(data) {
  return request({
    url: '/battle/dealUserData',
    method: 'post',
    data
  })
}

// 房间号处理
export function dealRoomData(data) {
  return request({
    url: '/battle/dealRoomData ',
    method: 'post',
    data
  })
}

// 连败数量 get
export function getFalseCount() {
  return request({
    url: '/battle/getFalseCount',
    method: 'post'
  })
}

// 连败数量 set
export function setFalseCount(data) {
  return request({
    url: '/battle/setFalseCount  ',
    method: 'post',
    data
  })
}
